replicateM n act performs the action
n times,
gathering the results.
Using
ApplicativeDo: '
replicateM 5 as' can be
understood as the
do expression
do a1 <- as
a2 <- as
a3 <- as
a4 <- as
a5 <- as
pure [a1,a2,a3,a4,a5]
Note the
Applicative constraint.